<extend name="Common/list-base" />

<block name="action">
    数据库中共有 {$data_count} 张表，共计 {$data_size}
</block>
<block name="search">
    <div class="input-group">
        <span class="text-icon">数据表名</span><input type="text" name="name" >
    </div>
</block>

<block name="list">
    <tr>
        <th width="30" class="tc"><input class="CheckAll" type="checkbox"></th>
        <th width="200">表名</th>
        <th>说明</th>
        <th width="100" class="tc">数据条数</th>
        <th width="100" class="tc">数据大小</th>
        <th width="100" class="tc">索引大小</th>
        <th width="200" class="tc">操作</th>
    </tr>
    <foreach name="list" item="v">
    <tr>
        <td class="tc"><input class="CheckOne" type="checkbox" name="pk[]" value="{$v.name}"></td>
        <td>{$v.name}</td>
        <td>{$v.comment}</td>
        <td class="tc">{$v.rows}</td>
        <td class="tc">{:format_bytes($v['data_length'])}</td>
        <td class="tc">{:format_bytes($v['index_length'])}</td>
        <td>
            <a class="AjaxHtml btn btn-blue" data-url="{:U('columns',array('table'=>$v['name']))}" href="javascript:;">数据表结构</a>
            <a class="AjaxHtml btn btn-blue" data-url="{:U('createSql',array('table'=>$v['name']))}" href="javascript:;">SQL语句</a>
        </td>
    </tr>
    </foreach>
</block>

<block name="batch">
    <div class="input-group">
        <span class="text-icon"> 分 组 </span><select name="batch"><option value="backup">备份数据库</option><option value="optimize">优化数据库</option><option value="repair">修复数据库</option></select>
    </div>
</block>